<header class="navbar navbar-fixed-top navbar-inverse">
  <div class="container">
    <%= link_to "购物", root_path, id: "logo" %>
    <nav>
      <ul class="nav navbar-nav navbar-right">
        <li><%= link_to "首页", home_path %></li>
        <li><%= link_to "帮助", help_path %></li>
        <% if logged_in? %>
            <li class="dropdown">
              <a href="#" class="dropdown-toggle" data-toggle="dropdown">
                个人中心 <b class="caret"></b>
              </a>
              <ul class="dropdown-menu">
                <li><%= link_to "个人资料", edit_user_path(current_user) %></li>
                <li><%= link_to "我的购物车", baskets_path %></li>
                <li class="divider"></li>
                <li>
                  <%= link_to "退出账号", logout_path, method: "delete" %>
                </li>
              </ul> </li>
        <% else %>
            <li><%= link_to "登录", login_path %></li>
        <% end %> </ul>
    </nav>
  </div>
</header>